package com.young.common.expression.dns;

import java.net.InetAddress;
import java.util.Map;

/**
 * @description：
 * @author: yangyahui01
 * @date: 11/29/24 2:46 PM
 */
public class DefaultResolver implements NamingResolver {
    public static final DefaultResolver INSTANCE = new DefaultResolver();

    public DefaultResolver() {
    }

    public InetAddress[] resolve(final String target) {
        try {
            return InetAddress.getAllByName(target);
        } catch (Exception var3) {
            return null;
        }
    }

    public InetAddress[] domainResolve(String domain) {
        return this.resolve(domain);
    }

    public InetAddress[] serviceResolve(String service) {
        return this.resolve(service);
    }

    public Map<String, String> copyDomainResolvers() {
        return null;
    }

    public Map<String, String> copyServiceResolvers() {
        return null;
    }

    public Map<String, String> copyServiceGroupResolvers() {
        return null;
    }
}

